feat(ios): derive Fake Treadmill speed from Apple Watch cadence - #4594
Merged
cagnulein merged 3 commits intoApr 30, 2026
Conversation
…eadmill mode
Adds opt-in setting `applewatch_as_treadmill_speed` (default off) that
derives Speed from Apple Watch step cadence inside cadenceFromAppleWatch()
when fakedevice_treadmill is also enabled. Reuses cadence_sensor_speed_ratio
("Wheel Ratio") for the multiplier and the existing virtual treadmill / RSC
broadcast pipeline. Useful for indoor walking and slow jogging with apps like
Kinomap or Zwift when no physical treadmill is connected.
Dual-gated behind both new toggles so normal treadmill users are unaffected.
When cadence reports exactly zero (user stopped), Speed is also zeroed; a
negative cadence (no fresh sample) leaves Speed unchanged. Settings appended
at the end of qzsettings and settings.qml per src/CLAUDE.md.
Owner
|
Thanks @miraicat the patch looks great, I will build an ios version tomorrow! |
Owner
|
sent the version! |
Contributor
Author
|
Tested on the TestFlight build. Slow jogging at ~180 spm (Apple Watch cadence) — Speed correctly derived from cadence. With Wheel Ratio at 0.046, getting ~4.1 km/h, pace and cadence numbers all consistent. Verified end-to-end with both Zwift and Kinomap on MacBook receiving over BLE FTMS — both work. Thanks for the quick turnaround! |
Contributor
Author
|
Quick follow-up: pushed a one-line help text correction (545f56e). Real-world testing showed the original 0.025-0.04 Wheel Ratio range was below typical slow jog speeds at 180 spm cadence (max ~3.6 km/h). Updated to 0.04-0.15 which covers walking through running. |
… help text Real-world testing showed the original 0.025-0.04 range was below typical slow jog speeds at 180 spm cadence (max ~3.6 km/h). Updated to 0.04-0.15 which covers walking through running.
miraicat
force-pushed
the
applewatch-as-treadmill-speed
branch
from
April 30, 2026 11:57
deba85e to
545f56e
Compare
Owner
|
that's great! |
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi Roberto — thanks for the quick reply and for inviting the PR.
Summary
This adds an opt-in iOS setting,
applewatch_as_treadmill_speed(default off), to derive treadmillSpeedfrom Apple Watch step cadence when Fake Treadmill mode is enabled.The feature reuses the existing Apple Watch cadence path in
treadmill::cadenceFromAppleWatch(), the existingcadence_sensor_speed_ratio("Wheel Ratio") multiplier, and the existing virtual treadmill / RSC broadcast pipeline.Use case
This is for indoor walking or slow jogging without a physical treadmill, while broadcasting to apps like Kinomap or Zwift via FTMS / RSC.
Apple Watch cadence is already available in QZ on iOS, but without a real treadmill there was no path to convert that cadence into broadcast
Speed, so users had to adjust the Speed tile manually.Design
applewatch_as_treadmill_speedandfakedevice_treadmill.cadence_sensor_speed_ratiosetting instead of adding another ratio control.0,Speedis also set to0so the virtual treadmill broadcast does not keep ghosting the previous speed.Speedunchanged.src/CLAUDE.md, the new setting is appended at the end of thesettings.qmlSettingsblock andallSettingsCountis bumped from882to883.UI
The toggle is placed next to "Fake Treadmill" in Experimental Features, since this feature requires Fake Treadmill mode.
The help text points users to Accessories > Cadence Sensor Options and suggests a Wheel Ratio around
0.025-0.04for walking / slow jogging. The existing cycling default of0.33would be too high for this use case.Testing plan
I have not been able to compile-verify locally because I do not have a Qt 5.15.2 + iOS toolchain set up, so I am relying on CI. Happy to iterate on anything that breaks or that you would like reshaped.
Related